<?

    /*
	   Core Functions 2009
	*/

   function dbconnect() 
            {
               $db_conn = @mysql_connect('localhost', 'root', '') or die ('Sorry, but the Server is too busy! Try later!');
	           if (!$db_conn) return false;
               if (!mysql_select_db('openoli')) return false;
			   
			   mysql_query("SET NAMES 'utf8' COLLATE 'utf8_general_ci'");
			   
               return $db_conn;			   
            }
			
	function get_all_variables()
            {   
               foreach ($_GET as $i => $value) 
                       { 
					   	  if (isset($_GET[$i]))
						     { 
					            global  $$i;
              	                $$i=$_GET[$i];
							 }
					   }

               foreach ($_SESSION as $i => $value) 
                       { 
					   	  if (isset($_SESSION[$i]))
						     {
					            global  $$i;
              	                $$i=$_SESSION[$i]; 
							 }
					   }  
					   
			   foreach ($_POST as $i => $value) 
                       { 
					   	  if (isset($_POST[$i]))
						     { 
					            global  $$i;
              	                $$i=$_POST[$i];
							 }
					   }  
					   
			   return 1;
	        }	
    
  
?>